
typedef void 		(*FINALIZER)		(VOID_STAR);

typedef struct _Slirp_Type {
   SLang_Class_Type	*class;		/* SLang type class for this type */
   unsigned int		typeid;		/* SLirp id for this type */
   struct _Slirp_Type	*parent;
   FINALIZER		finalizer;
} Slirp_Type;

typedef struct _Slirp_Ref {
   SLang_Array_Type	*array;
   SLang_Ref_Type	*ref;
   void			*data;
} Slirp_Ref;

typedef struct _Slirp_Opaque {
   Slirp_Type *type;
   void* instance;
   unsigned int owns_ref;
} Slirp_Opaque;

extern Slirp_Type	**Slirp_Opaque_Types;
extern unsigned int	Slirp_Num_Opaque_Types;


extern SLtype		Slirp_Opaque_Id;

extern SLtype		slirp_type_to_sltype	(unsigned int id);

extern int		Slirp_finalize_ref	(Slirp_Ref *sref,
      						SLtype sltype);

extern SLang_MMT_Type* 	create_opaque_mmt	(unsigned int id,
      						void *instance,
						unsigned int owns_ref);

extern int		SLang_push_opaque	(unsigned int id,
						void *instance,
						unsigned int owns_ref);

extern int		SLang_pop_opaque	(unsigned int id, 
      						Slirp_Opaque **opaque,
						SLang_MMT_Type **mmt);

extern int		pop_opaque_or_null	(unsigned int id,
      						Slirp_Opaque **opaque,
						SLang_MMT_Type **mmt);

extern int		pop_string_or_null 	(char **s);

extern int		pop_ref_or_null		(SLang_Ref_Type **r);

extern int		pop_anytype_or_null	(SLang_Any_Type **r);

extern int		pop_cstruct_or_null	(void **pstruct,
      						SLang_CStruct_Field_Type *);

extern int		pop_obj_or_null		(SLtype type, void **obj);

/* --- remaining content was automatically generated --- */


extern int allocate_glade_opaque_types(void);

extern unsigned int GtkOpaque_Id;
extern SLtype GtkOpaque_SLtype;
#define GtkOpaque_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GObject_Id;
extern SLtype GObject_SLtype;
#define GObject_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GdkDrawable_Id;
extern SLtype GdkDrawable_SLtype;
#define GdkDrawable_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GdkGC_Id;
extern SLtype GdkGC_SLtype;
#define GdkGC_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GdkPixbuf_Id;
extern SLtype GdkPixbuf_SLtype;
#define GdkPixbuf_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkObject_Id;
extern SLtype GtkObject_SLtype;
#define GtkObject_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkCellRenderer_Id;
extern SLtype GtkCellRenderer_SLtype;
#define GtkCellRenderer_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkCellRendererPixbuf_Id;
extern SLtype GtkCellRendererPixbuf_SLtype;
#define GtkCellRendererPixbuf_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkCellRendererText_Id;
extern SLtype GtkCellRendererText_SLtype;
#define GtkCellRendererText_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkCellRendererToggle_Id;
extern SLtype GtkCellRendererToggle_SLtype;
#define GtkCellRendererToggle_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkItemFactory_Id;
extern SLtype GtkItemFactory_SLtype;
#define GtkItemFactory_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkTreeViewColumn_Id;
extern SLtype GtkTreeViewColumn_SLtype;
#define GtkTreeViewColumn_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkTooltips_Id;
extern SLtype GtkTooltips_SLtype;
#define GtkTooltips_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkAdjustment_Id;
extern SLtype GtkAdjustment_SLtype;
#define GtkAdjustment_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkWidget_Id;
extern SLtype GtkWidget_SLtype;
#define GtkWidget_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GdkCursor_Id;
extern SLtype GdkCursor_SLtype;
#define GdkCursor_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GdkRegion_Id;
extern SLtype GdkRegion_SLtype;
#define GdkRegion_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkIconSource_Id;
extern SLtype GtkIconSource_SLtype;
#define GtkIconSource_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkIconSet_Id;
extern SLtype GtkIconSet_SLtype;
#define GtkIconSet_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkTreeIter_Id;
extern SLtype GtkTreeIter_SLtype;
#define GtkTreeIter_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkTextIter_Id;
extern SLtype GtkTextIter_SLtype;
#define GtkTextIter_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GtkTreePath_Id;
extern SLtype GtkTreePath_SLtype;
#define GtkTreePath_Id_push	SLANG_OPAQUE_TYPE_push
extern unsigned int GladeXML_Id;
extern SLtype GladeXML_SLtype;
#define GladeXML_Id_push	SLANG_OPAQUE_TYPE_push
